namespace CSharpPro
{
    public class Demo
    {
        public static bool IsLeapYear(int year)
        {
            // 闰年规则：能被4整除但不能被100整除，或能被400整除
            return (year % 4 == 0 && year % 100 != 0) || (year % 400 == 0);
        }
    }
}